package org.csu.sei.entity.DTO;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;
import org.csu.sei.entity.Banner;
@Data
public class BannerDTO {
    private String image;
    private String keywords;
    private Long newsId;

    public BannerDTO(){}
    public BannerDTO(Banner banner) {
        this.image = banner.getImage();
        this.keywords = banner.getKeywords();
        this.newsId=banner.getNewsId();
    }

    public static BannerDTO returnBanner(Banner banner){
        return new BannerDTO(banner);
    }
}
